
namespace SharpTalk.Core.Data
{
    using System;
    using System.Collections.Generic;

    /// <summary>
    /// 
    /// </summary>
    /// <typeparam name="T"></typeparam>
    public interface IDataProvider<T> : IDisposable
    {
        /// <summary>
        /// 
        /// </summary>
        void Initialize();
        /// <summary>
        /// 
        /// </summary>
        /// <param name="obj"></param>
        /// <returns></returns>
        bool Save(T obj);
        /// <summary>
        /// 
        /// </summary>
        /// <returns></returns>
        List<T> All();
        /// <summary>
        /// 
        /// </summary>
        /// <param name="obj"></param>
        /// <returns></returns>
        T Update(T obj);
        /// <summary>
        /// 
        /// </summary>
        /// <param name="obj"></param>
        /// <returns></returns>
        bool Delete(T obj);
        /// <summary>
        /// 
        /// </summary>
        /// <param name="guid"></param>
        /// <returns></returns>
        bool Delete(Guid guid);
        /// <summary>
        /// 
        /// </summary>
        /// <param name="guid"></param>
        /// <returns></returns>
        T Find(Guid guid);
        /// <summary>
        /// Deletes all data
        /// </summary>
        void ClearAll();
    }
}